#ifndef VSFREECAMERACONTROLLER_H
#define VSFREECAMERACONTROLLER_H
#include "VSMath.h"
#include "VSVector3.h"
#include "VSController.h"
namespace VSEngine2
{
	class VSStream;
	class VSGRAPHIC_API VSFreeCameraController : public VSController
	{
		//PRIORITY
		
		//RTTI
		DECLARE_RTTI;
	public:
		VSFreeCameraController();
		virtual ~VSFreeCameraController();
		VSREAL m_RotXDelta;
		VSREAL m_RotYDelta;
		VSREAL m_RotZDelta;
		VSREAL m_MoveDelta;
		VSVector3 m_MoveDirection;
		virtual bool UpdateEx(double dAppTime);
	public:
		static bool RegisterMainFactory();
	//protected:
		
		virtual unsigned int DiskUse()const;

		virtual bool Save(VSStream & rStream,unsigned int &iSaveUse)const;
		virtual bool Load(VSStream & rStream,unsigned int &iSaveUse);
	private:
		static bool InitialClassFactory();	
		static VSObject * FactoryFunc();
		static bool ms_bRegisterMainFactory;
	public:
		virtual bool Clone(const VSObject *pObject,unsigned int uiType);
	};

typedef VSPointer<VSFreeCameraController> VSFreeCameraControllerPtr;
}
#endif